<template>
    <div template>
        <bases :tonextlink="tonextlink" title="滑块">
            <div style="padding: 30px 20px 0; height: 50px;">
                <van-slider v-model="value" @change="onChange" />
            </div>
            <div style="padding: 30px 20px 0; height: 50px;">
                <van-slider v-model="value2" range @change="onChange2" />
            </div>
        </bases>
    </div>
</template>

<script>
import bases from './base.vue'
import { ref } from 'vue';
import { showToast } from 'vant';
export default {
    props: ['tonextlink'],
    components: {
        bases
    },
    setup() {
        const value = ref(50);
        const onChange = (value) => showToast('当前值：' + value);
        const value2 = ref([10, 50]);
        const onChange2 = (value) => showToast('当前值：' + value);
        return {
            value,
            onChange,
            value2,
            onChange2,
        };
    },
}
</script>
